<%--
  Created by IntelliJ IDEA.
  User: sun
  Date: 2020/11/24
  Time: 14:56
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <title>留言</title>

</head>
<style>
    #div1{
       height: 80%;

    }
    #comment{
        width: 500px;
        height: 300px;
        position: absolute;
        left:500px;
        top:250px;

    }
    #ti{
        position: absolute;
        left: 940px;
        top:580px;
    }
    #liu{
        position: absolute;
        left: 500px;
        top:148px;}
   .red{
        position: absolute;
        left: 860px;
        top:555px;
    }
    #stuName{
        float: left;
        width:270px;
        height:40px;
        margin-top:100px;
        margin-left: 500px;
    }

</style>
<script type="text/javascript">
    function setShowLength(obj, maxlength, id) {
        var rem = maxlength - obj.value.length;
        var wid = id;
        if (rem < 0){
            rem = 0;
        }
        document.getElementById(wid).innerHTML = "还可以输入" + rem + "字数";
    }
</script>
<body>
<jsp:include page="hade.jsp"/>
<form action="/remarks/addRemarks" method="post">

        <div id="div1">
            <label for="comment" id="liu" ><h3>留言：</h3></label>
            <textarea  id="comment" name="rDis" maxlength="200" placeholder="留下你想说的" value="{$p.leaveCenter}" name="leaveCenter"onkeyup="javascript:setShowLength(this, 200, 'cost_tpl_title_length')"></textarea>
            <span class="red" id="cost_tpl_title_length">还可以输入200字数</span>
            <button type="submit" class="btn btn-primary" id="ti">提交</button>
        </div>
    <%--<input name="title" type="text" size="50" value="{$p.title}" maxlength="15" onkeyup="javascript:setShowLength(this, 15, 'cost_tpl_title_length');">--%>

   <%-- <span class="red" id="cost_tpl_title_length">还可以输入15字数</span>--%>
</form>
</body>
</html>
